package com.shwread.android.qysw.tools;


import com.shwread.android.qysw.QyReaderApp;

public class DataKeeperHelper {

    private static final String TAG_USER_STEP_CACHE = "tag_user_step_cache";
    DataKeeper dataKeeper;
    DataKeeper userStepDataKeeper;
    DataKeeper userInfoDataKeeper;
    DataKeeper userDailyDataKeeper;

    private DataKeeperHelper() {
        dataKeeper = new DataKeeper(QyReaderApp.getApplication(), QyReaderApp.getApplication().getPackageName());
        userStepDataKeeper = new DataKeeper(QyReaderApp.getApplication(), TAG_USER_STEP_CACHE);
        userInfoDataKeeper = new DataKeeper(QyReaderApp.getApplication(), TAG_USER_STEP_CACHE);
        userDailyDataKeeper = new DataKeeper(QyReaderApp.getApplication(), TAG_USER_STEP_CACHE);
    }

    private static class DataKeeperHolder {
        public final static DataKeeperHelper sington = new DataKeeperHelper();
    }

    public static DataKeeperHelper getInstance() {
        return DataKeeperHolder.sington;
    }

    public DataKeeper getUserStepCache() {
        return userStepDataKeeper;
    }

    public DataKeeper getUserInfoCache() {
        return userInfoDataKeeper;
    }

    public DataKeeper getUserDailyStepCache() {
        return userDailyDataKeeper;
    }

}
